import VueRouter from 'vue-router'



// 导入界面
import login from './pages/login.vue'
import home from './pages/home.vue'
import write from './pages/write.vue'
import article from './pages/article.vue'
import componentcol from './pages/componentscollection.vue'

// 导入组件
import signin from './components/signin.vue'
import signup from './components/signup.vue'
// import manuscript from './components/manuscripts.vue'
import authsign from './components/authsign.vue'


// Test中的组件
import basebutton from './test/BaseButton.vue'
import AuthSignFooter from './test/AuthSignFooter.vue'
import ButtonAntiColor from './test/ButtonAntiColor.vue'
import mytest from './test/mytest.vue'
import user from './test/user.vue'

import fa from './test_slot/fa.vue'
 

// 3. 创建路由对象
var router = new VueRouter({
  routes: [
    {path: '/',component:home},
    {path: '/login',component: login,
      redirect:'/login/signin',
      children:[{path:"signin",name:"signin",component:signin},{path:"signup",component:signup}]},
    // {path: '/login',component: login},
    // {path:'/login/signin',component:signin},
    {path: '/home' ,component:home},
    {path:'/write',component:write},
    {path:'/article',component:article},
    {path:'/conponentcol',component:componentcol},
    {
      path:'/authUser',
      name:'login',
      component:authsign
    },
    {
      path:'/user/:username',
      name:'user',
      component:user
    },
    {path:'/basebutton',name:'p',component:basebutton},
    {path:'/AuthSignFooter',name:'s',component:AuthSignFooter},
    {path:'/ButtonAntiColor',name:'s',component:ButtonAntiColor},   
    {path:'/fa',name:'s',component:fa},   
    {path:'/mytest',name:'ss',component:mytest}

    // {path:'/',name:'',component:,}
  ]
})

// 把路由对象暴露出去
export default router 